Pythagorean Triple Calculator

A Pythagorean Triple is any a, b, & c where a 2 + b 2 = c 2

Let n and m be integers where n > m. Then define

a = n 2 - m 2
b = 2 n m
c = n 2 + m 2
The three numbers a, b, & c always form a Pythagorean Triple. The proof is simple:

( n 2 - m 2 ) 2 + ( 2 m n ) 2 = n 4 - 2 n 2 m 2 + m 4 + 4 n 2 m 2
= n 4 + 2 n 2 m 2 + m 4
= ( n 2 + m 2 ) 2

The calculator returns a list of Pythagorean Triples up to any limit defined. To use the calculator simply enter the upper limit for the calculation. Then hit the buttom to calculate the list.

Only coprime and differing parity triples are listed. Coprime numbers do not have a common divisor greater then one. Differing parity means that two numbers are not both even or both odd.

A limit of 100 will produce about 2000 triples.

The second function of the calculator is to find a Pythagorean triple that closely approximates the desired angle. These can then be used for accurately setting an angle on any surface. Enter the desired angle and the triple limit. The first triple found to approximate the angle within the triple upper limit is displayed along with the error. Raising the limit (note the limit comment above) should find triples with smaller errors.




Enter a limit and hit the button: